package vip.sunxy.aspectdemo;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import vip.sunxy.aspectdemo.model.Person;
import vip.sunxy.aspectdemo.service.HelloService;

/**
 * @author Aiguo
 */

@RestController
@RequestMapping("hello/")
public class HelloController {
    @Autowired
    private HelloService helloService;

    @GetMapping("say_hello1/{name}")
    public Person sayHello1(@PathVariable String name){
        return helloService.sayHello1(name);
    }
}
